Skip to content

ci: adopt consolidated ospo-reusable-workflows release.yaml#552

Merged
jmeridth merged 2 commits into
mainfrom
ci/consolidated-release-workflow
May 10, 2026
Merged

ci: adopt consolidated ospo-reusable-workflows release.yaml#552
jmeridth merged 2 commits into
mainfrom
ci/consolidated-release-workflow

Conversation

@jmeridth
Copy link
Copy Markdown
Collaborator

Pull Request

Proposed Changes

Collapse the three legacy release / release_image / release_discussion job calls into a single call to the consolidated release.yaml reusable workflow at v1.0.0 (592067a6...). The new workflow handles GitHub release creation, container image build/push to GHCR, build provenance attestation, and the announcement discussion in one draft-first pipeline.

Also add a "💥 Breaking Changes" category to release-drafter.yml, matching the upstream release-drafter template (github-community-projects/ospo-reusable-workflows#134). The breaking label was already wired up under version-resolver.major, so this just surfaces those PRs in their own changelog section.

Notes for reviewers

  • The job-level permission block now lists the union of what the called workflow's internal jobs need. A uses: caller can only grant — never expand — what the reusable workflow requests, so missing perms here silently disable features instead of erroring.
  • image-registry / image-registry-username moved from secrets: to inputs in v1.0.0 and default to ghcr.io / github.actor. Both defaults match the previous values, so the inputs are omitted.
  • image-registry-password stays a secret and continues using GITHUB_TOKEN for GHCR pushes.
  • The reusable workflow's release_discussion job validates the discussion secrets at the step level and skips with a notice if they're unset, so the workflow keeps working even if the discussion secrets aren't configured for this repo.

Readiness Checklist

Author/Contributor

  • If documentation is needed for this change, has that been included in this pull request
  • run make lint and fix any issues that you have introduced
  • run make test and ensure you have test coverage for the lines you are introducing

Testing

  • make lint — clean (mypy 0 issues across 12 source files, black 12 files unchanged).
  • make test — 174 tests + 32 subtests pass, coverage 98.97%.
  • End-to-end release flow is not exercised locally; first real validation will be the next merged PR carrying a feature / fix / breaking / vuln / release label that fires pull_request_target: closed. Watch for: draft release created by release-drafter, container image published to ghcr.io/$REPO, build provenance attestation succeeding, release announcement discussion created (if RELEASE_DISCUSSION_* secrets are set), then publish_release flipping the draft to published.

## What

Collapse the three legacy `release` / `release_image` / `release_discussion` job calls into a single call to the consolidated `release.yaml` reusable workflow at v1.0.0 (`592067a6...`). Pass `image-name`, `create-attestation: true`, and `create-discussion: true` so the workflow handles GitHub release, container image build/push to GHCR, build provenance attestation, and announcement discussion in one draft-first pipeline. Also add a "💥 Breaking Changes" category to `release-drafter.yml`.

## Why

The legacy three-workflow setup forced callers to wire up the same job chain by hand in every repo and made it easy for permissions, secrets, and ordering to drift. v1.0.0 of ospo-reusable-workflows owns the chain internally and exposes a single entry point. The "Breaking Changes" category matches the upstream release-drafter template (github-community-projects/ospo-reusable-workflows#134); the `breaking` label already maps to a major bump in `version-resolver`, so this just surfaces those PRs in their own changelog section.

## Notes

- The job-level permission block now lists the union of what the called workflow's internal jobs need (contents/pull-requests/packages/id-token/attestations/discussions). A `uses:` caller can only grant — never expand — what the reusable workflow requests, so missing perms here silently disable features instead of erroring.
- `image-registry` and `image-registry-username` moved from `secrets:` to inputs in v1.0.0 (defaults to `ghcr.io` and `github.actor`). Both defaults match the previous explicit values, so they're omitted.
- `image-registry-password` stays a secret and continues to use `GITHUB_TOKEN` for ghcr.io pushes.
- The reusable workflow's `release_discussion` job validates the discussion secrets at the step level and skips with a notice if they're unset, so the workflow keeps working even if the discussion secrets aren't configured.

Signed-off-by: jmeridth <jmeridth@gmail.com>
@jmeridth jmeridth added the Mark Ready When Ready Automatically mark draft PR ready when checks pass label May 10, 2026
@jmeridth jmeridth self-assigned this May 10, 2026
@jmeridth jmeridth added the Mark Ready When Ready Automatically mark draft PR ready when checks pass label May 10, 2026
Single-space before `#` so prettier (via super-linter) accepts the workflow file. No behavior change.

Signed-off-by: jmeridth <jmeridth@gmail.com>
@github-actions github-actions Bot marked this pull request as ready for review May 10, 2026 23:34
@github-actions github-actions Bot requested a review from zkoppert as a code owner May 10, 2026 23:34
@github-actions github-actions Bot removed the Mark Ready When Ready Automatically mark draft PR ready when checks pass label May 10, 2026
@jmeridth jmeridth merged commit bdb41be into main May 10, 2026
36 checks passed
@jmeridth jmeridth deleted the ci/consolidated-release-workflow branch May 10, 2026 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant